import request from '@/utils/request'

export function getLocList() {
  return request({
    url: '/business/maplocation/list',
    method: 'get',
    // params: { token }
  })
}
export function getRegionList() {
  return request({
    url: '/business/region/listAll',
    method: 'get',
    // params: { token }
  })
}
export function add(data) {
  return request({
    url: '/business/region/save',
    method: 'post',
    data
  })
}

export function del(id) {
  return request({
    url: '/business/region/delete',
    method: 'post',
    data: [id]
  })
}

export function edit(data) {
  return request({
    url: '/business/region/update',
    method: 'post',
    data
  })
}
export function get(id) {
  return request({
    url: `/business/region/info/${id}`,
    method: 'get'
  })
}

export default { getLocList, getRegionList, add, del, edit, get }
